package com.hjm.ui.common.adapter;

import android.util.ArrayMap;
import android.view.View;
import android.widget.ImageView;
import android.widget.TextView;

import androidx.annotation.NonNull;
import androidx.recyclerview.widget.RecyclerView;

import java.util.List;
import java.util.Map;

public class BaseViewHolder extends RecyclerView.ViewHolder{
    public Map<Integer, View> viewMap;

    public BaseViewHolder(@NonNull View itemView,Map<Integer, Class<?>> classMap) {
        super(itemView);
        viewMap = new ArrayMap<>();
        for (Map.Entry<Integer, Class<?>> entry : classMap.entrySet()) {
            viewMap.put(entry.getKey(), (ImageView)itemView.findViewById(entry.getKey()));
        }
    }
}
